<div class="content_article">

  <div id="acct">            
  <?php 
               if($account=$this->session->userdata('user')){if($account->activated !=1){
                ?>
                <blockquote>
                    <p>Your email has not been verified.
                    You will not be able to cashout until you do so.<br />
                    <a href="<?php echo base_url().'auth/send_again'?>">Click Here to Resend Verification Email</a>
                    </p>                
                </blockquote>
                <?php }else{?>
                <h4>&nbsp;&nbsp;Cashout</h4>                
                <?php 
                    if($this->session->userdata('loi')){
                        echo '<blockquote>'.$this->session->userdata('loi').'</blockquote>';
                    }
                ?>
                <?php 
                if(!empty($pay)){
                    echo '<table>
					<tr>
						<th>#</th><th>Point</th><th>Status</th><th>Method</th><th>PP/LR</th><th>Date</th>
					</tr>';
                    $i=0;
                    foreach($pay as $payout){
                        $i++;
                        if($i%2==0){echo '<tr class="row-a">';}else echo '<tr class="row-b">';
                        echo '<td>'.$i.'</td><td>'.$payout->point.'</td><td>'.$payout->status.'</td><td>'.$payout->method.'</td><td>'.$payout->accpay.'</td><td>'.$payout->created.'</td>';
                        echo '</tr>';
                    }
                    echo '</table>';
                }
                
                 ?>
				<form method="POST" action="<?php echo base_url();?>user/payout">			
				<table>
					<tr>
						<th class="first" colspan="2">Withdraw money Earned(100point=1$)</th>
					</tr>
					<tr class="row-a">
						<td>Payout Method</td>
						<td> 
                        <select name="method">
                            <option value="Paypal">Paypal</option>
                            <option value="Liberty Reserve">Liberty Reserve</option>
                          </td>
					</tr>					
					<tr class="row-b">
					<td>Paypal or LR </td>
						<td><input type="text" value="" name="accpay" /></td>
					</tr>
					<tr class="row-a">
					   <td>Point</td>
						<td><input type="text" value="" name="point" /></td>
					</tr>
                    <tr>
						<th class="first" colspan="2"><input type="submit" value="Cashout " /></th>
					</tr>
				</table>
                </form>
                <?php }}?>
                </div> 
</div>
               